<?xml version='1.0' encoding='UTF-8' ?>
<!DOCTYPE composition PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<ui:composition xmlns:ui="http://java.sun.com/jsf/facelets"
                xmlns:h="http://java.sun.com/jsf/html"
                xmlns:p="http://primefaces.org/ui"
                xmlns:gp="http://java.sun.com/jsf/composite/gpymes"
                xmlns:f="http://java.sun.com/jsf/core">



    <div style="text-align: center; width: 100%;height: 100%;background-color: #ddd">
        <br/>
        <br/>
        <br/>
        <div style="font-size: 28pt; font-weight: bold">
            <h:outputText value="#{terminalBean.ticketActual.total}">
                <f:convertNumber locale="#{formato.locale}"/>
            </h:outputText> G.
        </div>
        <br/>


        <table style="width: 350px; margin: 0 auto 0 auto; ">
            <tr>
                <td style="width: 350px;" colspan="2">
                    <p:dataGrid value="#{terminalBean.ticketActual.ticketPagos}" var="p" style="background-color: #ddd;padding: 0;margin: 0;border:none;background: none;"
                                columns="1">
                        <div style="width: 350px;text-align: left;background-color: #ddd;padding: 0;margin: 0;">
                            <h:outputText value="#{p.descripcion}"/>
                            <p:inputText value="#{p.importe}" style="width: 350px"/>
                        </div>
                    </p:dataGrid>
                </td>
            </tr>
            <tr>
                <td align="left">
                    <h:outputText value="Pagado: "/>
                </td>
                <td align="right">
                    <h:outputText value="50.000 G"/>
                </td>
            </tr>
            <tr>
                <td align="left">
                    <h:outputText value="Restante: "/>
                </td>
                <td align="right">
                    <h:outputText value="10.000 G"/>
                </td>
            </tr>
            <tr>
                <td align="left">
                    <h:outputText value="Cambio: "/>
                </td>
                <td align="right">
                    <h:outputText value="10.000 G"/>
                </td>
            </tr>
        </table>   

        <div style="border-top: 1px solid #ddd; background-color: #ccc; float: bottom;position: absolute; z-index: 999;height: 100px;top:83%;width: 100%;">
            <table style="margin-left: 20px; margin-top: 10px">
                <tr>
                    <td>
                        <p:commandButton value="Atras" action="#{terminalBean.atras()}" style="width: 75px; height: 75px;"
                                         update="@(.panelIzquierdo)"/>
                    </td>   
                    <td>
                        <p:commandButton value="Validar" action="#{terminalBean.crearTicket()}" style="width: 75px; height: 75px;"
                                         update="@(.panelIzquierdo, .detalles)"/>
                    </td>   
                </tr>
            </table>


        </div>
    </div>








</ui:composition>
